Whoever it was at Apple that decided to notify you of a system error with a picture of a bomb has a place in my heart right next to Hitler. Its bad enough to watch your computer crash, but to be greeted with a whimsical graphic each time it happens is an added insult. (At least we don’t get the dreaded “Guru” of the Amiga™ computer, so I guess I could count my blessings.)
Well, what use is a dead Macintosh anyway? You may be surprised. There are several system failures that can cause the dreaded bomb, and I will try to make sense of them with this article. I have broken them down into three categories: Boot Failures, System Failures, and Application Failures.
••• Boot Failures •••
A "Boot Failure" is a complete inability to start up your Macintosh. If this happens you will get a "sad Mac" icon and have to try again. Boot failures can occur for many reasons, the first and worst is for the Mac to fail its internal diagnostic tests. This indicates a hardware problem and will require a technician to fix. The second possibility is that the system file is not correct. This can be checked by inserting another disk. The most common problem is simply an attempt to start the Mac with a non-system disk in the default drive. Other possibilities include the lack of the Finder on the disk, a bad sector in the boot disk, or something similar. One possibility that should not be overlooked is a depressed programmers switch, assuming you have one installed. The interrupt button can get stuck sometimes and will seem to be a hardware failure.
••• System Failures •••
A "System Failure" occurs when the underlying software of the Macintosh becomes corrupted, or when the internal memory management gets fouled up. These are by far the most common (and serious) errors for day to day use of the Macintosh. In almost all cases system failures are the result of an error in programming. Here is a brief rundown of the errors that are the most common.
• 01 -- Bus Error - This error occurs whenever a program attempts to access an invalid memory location. In most cases this error only occurs on the Macintosh II or SE/30 family of Macs. Usually this is caused by an attempt to read or write to a memory address that is outside of the range of the available RAM.
• 02 -- Address Error - In programming terms this is an attemt to make a long word or word reference to an odd memory address. Because words and long words are restricted to even addresses, the system detects this as a spurious address and brings down the house. (For those of you who are confused, a “word” is a two byte chunk of memory, and a “long word” is a four byte chunk.)
• 03 -- Illegal Instruction - The heart of your Macintosh is a processor chip, either the Motorola 68000, 68020, or the newly added 68030. A processor is driven by certain codes (“op codes,” in programming lingo) that are decoded by the processor into specific actions. If the processor is expecting a code and what it gets does not match its internal list of op codes, then it barfs, and you see the old familiar bomb.
• 04 -- Zero Divide - This is simple enough, and there is no excuse for it. This simply means that the programmer told the processor to divide a 0 into some other number. Mathematically the result would be infinite. Realistically the result is a bomb.
• 05 -- Check Exception - This is simple enough to explain to a programmer, but may be a little more difficult for a layman. In most cases this error is a result of an index out of range. For example, if you declare an array of 20 elements and try to access the 21st, you will get a check exception. This is easy to do, and you may see errors like this in mathematical programs fairly often. This is programmer accessible, which means the programmer can turn off this feature to speed up his program. Unfortunately that means a bad array reference would not be reported.
• 06 -- TrapV Exception - This is pretty esoteric, and there is no easy way to explain it without a complete understanding of the Mac system. (Sorry.)
• 07 -- Privelege Exception - See 06.
• 08 -- Trace Exception - The 68000 chip can be set to "trace" itself, but this is a debugging tool that interferes with normal execution.
• 09 -- Line 1010 exception - This is a hexidecimal “A” code, and all Macintosh ROM calls are accessed via a “Trap” with a leading “A” in the trap word. If the processor cannot execute a “Trap” routine (if the ROM is inaccessible for some reason) then this is returned. The Macintosh ROM is available by use of a “Trap Vector Table” which is in turn accessed through a microprocessor instruction that starts with the hexidecimal “A.”
• 10 -- Line 1111 exception - This is a hexidecimal “F“ code and it is similar to a Line 1010 exception. The 68000 series of Motorola chips allows computer designers to access special “Trap” calls either through leading “A’s” or leading “F’s.” Since the Macintosh only uses the “A” Traps for ROM calls, a Line 1111 exception indicates a totally wacked out program. It should never happen.
• 11 -- Miscellaneous exception - Yes, even chip designers have “clean up hitters,” and this error means just about anything that is not already covered.
• 12 -- Unimplemented Core Routine - Wow, doesn’t that sound techno-cool? What the heck does it mean? Well its simple enough. It happens if the program attempts to execute a “Trap” (there’s that word again) and there is no such trap defined. (For the sake of simplicity, any ROM call is usually accessed through the use of “Traps.”) When the processor detects a trap (which, as we see from errors 9 and 10 above, is a special instruction that “interrupts” the processor and transfers execution to a new location based on a list of memory locations called the “trap vector table.”) but cannot find a comparable listing for the trap in the “trap vector table” it responds with this error. This is another rare error.
• 13 -- Spurious Interrupt - Never Mind. Suffice it to say that this is a bad piece of luck.
• 14 -- I/O system error - This indicates an error in the file system or the device manager system. More about this under the heading “Application failures.”
• 15 -- Segment Loader error - This indicates that, for some unknown reason, the system could not load a needed segment from disk and into RAM memory. This error is usually reported when the program is launched, so it doesn’t usually cause a great deal of data loss.
• 16 -- Floating Point Error - Another mathematical error that should never happen.
• 17 - 24 -- Package Loading Error - These error codes are returned when the system tries to read special sections of the system file known as “packages.” These packages are essential for the proper execution of the Macintosh, so this results in the too-familiar bomb.
• 25 -- Memory allocation error - The program requested a chunk of memory, but the Mac could not find enough memory for the program to use. This is a fairly common error, and usually indicates a failure of the programmer to keep track of the memory he has already allocated.
• 26 -- Segment Loader Error - An attempt to launch a program without a “CODE resource of 0.” This usually means the “program” is not really a program.
• 28 -- Stack Overflow Error - This is tough to explain to non-programmers. Basically it means that two competing areas of memory (called the “Stack” and the “Heap”) have collided.
• 41 -- Finder error - An attempt to boot with a disk which does not contain a copy of the Finder.
• 100 -- Mount Volume Error - The system file is bunged up.
••• Application Failures •••
Users don’t usually see too many of these errors because good programmers can spot them before they get to the user. Here they are anyway.
• -33 -- Directory full error - The folder cannot hold any more files.
• -34 -- Disk full error - The disk is full.
• -35 -- Specified volume does not exist.
• -36 -- Generic input/output error.
• -37 -- Incorrect file name.
• -38 -- Attempt to read or write an unopened file.
• -39 -- Attempt to read past end of file marker.
• -40 -- Attempt to move before start of file.
• -42 -- Attempt to open too many files.
• -43 -- The file was not found.
• -44 -- The disk is write-protected.
• -45 -- The file is set as “locked.”
• -46 -- The Disk is locked.
• -47 -- The file is busy.
• -48 -- Cannot create two files with same name or number.
• -49 -- Attempt to open two paths to the same file for writing.
• -50 -- Parameter block error.
• -51 -- The files reference number is bogus.
• -53 -- The specified volume (disk) is not present in any drive.
• -54 -- Attempt to open a locked file for writing.
• -57 -- Not a Macintosh disk.
• -59 -- Attempt to rename a file failed.
• -60 -- Master directory is trashed.
I hope you never need this information, but the next time you see that smoking bomb, this will tell you why.